#include "threadPool.hpp"
#include <memory>
#include "task.hpp"
using namespace threadPoolModule;

int main()
{
    ENABLE_CONSOLE_LOG();
    threadPool<task_t>::getInstance()->start();
    char c;
    int cnt = 5;
    while (cnt)
    {
        // std::cin >> c;
        threadPool<task_t>::getInstance()->equeue(push);
        cnt--;
        sleep(1);
    }
    threadPool<task_t>::getInstance()->stop();
    threadPool<task_t>::getInstance()->wait();

    // std::unique_ptr<threadPool<task_t>> tp = std::make_unique<threadPool<task_t>>();

    // tp->start();

    // int cnt = 10;
    // while (cnt--)
    // {
    //     tp->equeue(push);
    //     sleep(1);
    // }

    // tp->stop();

    // tp->wait();
}